<template>
  <div class="project-detail-body p10">
    <el-tabs v-model="activeName">
      <el-tab-pane label="详情" name="detail">
        <detail :detail="detail" />
      </el-tab-pane>
      <el-tab-pane label="影像" name="dicom">
        <viewer :detail="detail" />
      </el-tab-pane>
      <el-tab-pane label="附件" name="accessory">Accessory</el-tab-pane>
      <el-tab-pane label="质疑" name="query">
        <query :detail="detail" />
      </el-tab-pane>
      <el-tab-pane label="表单" name="form">Form</el-tab-pane>
    </el-tabs>
  </div>

  <div class="project-detail-footer">
    <div class="project-detail-footer__header">
      <span>操作日志</span>
      <span class="log-num">0</span>
    </div>
    <div class="project-detail-footer__body">
      <ul class="log-list">
        <li>xxx创建了xxx</li>
      </ul>
    </div>
  </div>
</template>

<script lang="ts" setup>
import { PropType, ref } from 'vue'

import Detail from './detail.vue'
import Query from './query.vue'
import Viewer from './viewer.vue'

import IBaseObj from '#/index'
defineProps({
  detail: {
    type: Object as PropType<IBaseObj>,
    default: () => {},
  },
})

const activeName = ref('detail')

const init = () => {
  activeName.value = 'detail'
}

defineExpose({
  init,
})
</script>
